Skip to content

OCI format ADR#115

Merged
SecKatie merged 10 commits into
LobsterTrap:mainfrom
dmartinol:oci_format_adr
Jun 15, 2026
Merged

OCI format ADR#115
SecKatie merged 10 commits into
LobsterTrap:mainfrom
dmartinol:oci_format_adr

Conversation

@dmartinol

@dmartinol dmartinol commented Apr 29, 2026

Copy link
Copy Markdown
Collaborator

Summary

An ADR to integrate OCI format for lola modules.

Related Issues

NA

Test Plan

  • ADR follows the project template format

AI Disclosure

AI-assisted with Claude Code

Summary by CodeRabbit

Documentation

  • Added architecture decision records defining planned OCI-based artifact distribution as an optional format alongside existing sources
  • Added a detailed CLI exploration covering OCI workflows, including build, push, sign, verify, inspect, and OCI-aware enhancements to module add/install/list
  • Documented security-first behavior (verification defaults, digest pinning) and multiple deployment modes, plus marketplace-to-OCI integration guidance

@dmartinol dmartinol requested a review from mrbrandao April 29, 2026 18:03
@coderabbitai

coderabbitai Bot commented Apr 29, 2026

Copy link
Copy Markdown

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: c0e317fb-5577-462c-ae23-30aa0492ec25

📥 Commits

Reviewing files that changed from the base of the PR and between 56dbf21 and 4642f7e.

📒 Files selected for processing (2)
  • docs/adr/oci-format.md
  • docs/adr/oci-format/oci-cli-exploration.md
✅ Files skipped from review due to trivial changes (2)
  • docs/adr/oci-format.md
  • docs/adr/oci-format/oci-cli-exploration.md

📝 Walkthrough

Walkthrough

This PR introduces two ADR documents that establish Lola's approach to OCI-based artifact distribution. The main ADR outlines the decision to support oci:// module references using skillimage-based Go implementation, specifies three deployment modes, and records consequences and alternatives. The companion CLI exploration document details the full command design, including new OCI commands (build, push, sign, verify, inspect) and enhancements to existing commands, with practical workflows and a phased implementation plan.

Changes

OCI Support Decision and CLI Specification

Layer / File(s) Summary
OCI Decision and Architecture
docs/adr/oci-format.md
ADR document establishing OCI as optional module distribution format alongside Git/Zip/Tar, with skillimage-based Go implementation, three deployment modes (local unpack, container mounting, cloud/cluster), verification-before-extraction default, rationale with positive/negative consequences, rejected alternatives, implementation outline, and references.
OCI CLI Architecture and Design Principles
docs/adr/oci-format/oci-cli-exploration.md (intro, foundation)
Describes architectural basis for OCI support including single-layer skillimage packaging, module/skill/command/agent layout, and format-neutral CLI design principles.
New OCI Artifact Commands
docs/adr/oci-format/oci-cli-exploration.md (build, validation, push, sign, verify, inspect)
Specifies lola build with skill.yaml and SKILL.md frontmatter mapping, module validation with multiple implementation approaches, and additional OCI commands for publishing, remote signing with Cosign, signature/provenance verification, and metadata inspection.
OCI Integration with Existing Commands
docs/adr/oci-format/oci-cli-exploration.md (mod add, install, mod ls)
Enhances existing commands: lola mod add adds OCI registry support with security defaults and verification controls; lola install adds deployment mode selection; lola mod ls displays OCI metadata.
Marketplace and OCI Integration
docs/adr/oci-format/oci-cli-exploration.md (marketplace section)
Defines marketplaces as source-agnostic discovery catalogs referencing OCI repositories via repository fields, with multi-format support and clear separation between discovery and distribution.
OCI Workflows and End-to-End Use Cases
docs/adr/oci-format/oci-cli-exploration.md (workflows, examples)
Demonstrates build-sign-verify-install patterns for developers, enterprise users, containerized deployments, Kubernetes Job administration, and multi-format installations.
Operations, Configuration, and Implementation Plan
docs/adr/oci-format/oci-cli-exploration.md (error handling, enterprise config, phasing, compatibility)
Error handling with example failure messages and troubleshooting, optional enterprise policy configuration (~/.lola/config.yaml), environment variable overrides, phased delivery (Phase 0–4), future enhancements (bundle create, enhanced search), and backward compatibility guarantees.

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~8 minutes

Suggested labels

documentation, enhancement

Suggested reviewers

  • SecKatie
  • sergio-correia

Poem

🐰 Documents bloom in the garden of Lola's design,
OCI images dance with signatures so fine,
Skillimage partners, in layers so keen,
The clearest ADR path ever seen!

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title 'OCI format ADR' directly and clearly identifies the main change: introducing an Architecture Decision Record for OCI format support in Lola modules.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 4

🧹 Nitpick comments (3)
docs/adr/0007-oci-format.md (2)

445-445: Use “CLI compatibility” instead of “CLI interface compatibility.”

“Interface” is redundant in this phrase.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@docs/adr/0007-oci-format.md` at line 445, Update the phrasing in the ADR text
by replacing the phrase "CLI interface compatibility (Click → Cobra)" with the
concise "CLI compatibility (Click → Cobra)"; locate the exact string "CLI
interface compatibility (Click → Cobra)" in docs/adr/0007-oci-format.md and
change it to "CLI compatibility (Click → Cobra)" so the word "interface" is
removed.

365-365: Add language identifiers to fenced code blocks.

Fences opened on Line 365, Line 392, and Line 410 are missing a language tag, which triggers MD040. Using text for tree/architecture diagrams keeps lint clean and readability high.

Proposed doc-only diff
-```
+```text
 OCI Image:
 ...
-```
+```

-```
+```text
 .lola/modules/module-name/
 ...
-```
+```

-```
+```text
 lola (Go binary)
 ...
-```
+```

Also applies to: 392-392, 410-410

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@docs/adr/0007-oci-format.md` at line 365, Three fenced code blocks are
missing language identifiers causing MD040; update the three backtick fences
that surround the blocks starting with "OCI Image:",
".lola/modules/module-name/", and "lola (Go binary)" to use a language tag (use
"text") so each opening fence becomes ```text and the corresponding closing
fence remains ```, keeping the block contents unchanged; apply the same change
for the other occurrences mentioned (the blocks around those three headings).
docs/adr/0007-oci-format/oci-cli-exploration.md (1)

29-29: Add a language tag to the fenced block at Line 29.

This currently triggers MD040; text is appropriate for the tree diagram.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@docs/adr/0007-oci-format/oci-cli-exploration.md` at line 29, The fenced code
block that contains the tree diagram is missing a language tag (triggering
MD040); update the opening backtick fence for that block (the fenced block
beginning at the tree diagram around line 29) to include the language tag "text"
(e.g., ```text) so the markdown linter recognizes the code block type.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Inline comments:
In `@docs/adr/0007-oci-format/oci-cli-exploration.md`:
- Around line 1441-1443: The documented provenance flag is inconsistent: replace
the mention of `--skip-provenance` with the already defined
`--skip-verification` (or explicitly document both if provenance has a separate
flag) so the "Provenance verification" bullet uses the same flag names as the
earlier OCI command options; update the line that reads `Provenance
verification: **Enabled** for OCI modules (use --skip-provenance flag to
disable)` to reference `--skip-verification` (or add clarifying text listing
both `--skip-verification` and `--skip-provenance`) to keep
`--skip-verification` and `--skip-provenance` consistent across the doc.
- Around line 909-913: The docs show conflicting command flows for installing
OCI modules (sometimes using the two-step "lola mod add <source>" then "lola
install <module> -a <assistant>" flow, and other times invoking "lola install
oci://..." directly, and option names like "--verify-signature" don't match
earlier specs); pick one canonical contract (either the two-step registry flow
using "lola mod add" + "lola install <module> -a <assistant>" or the
direct-install flow "lola install oci://<...> -a <assistant>"), then update all
examples and error messages to that contract consistently (including normalizing
option names such as "--verify-signature" to the agreed flag name), and audit
the referenced sections (the current examples and errors around the OCI CLI
exploration doc, plus the other occurrences noted) to ensure every example,
error text, and option usage matches the chosen command format and flag names
(search for "lola mod add", "lola install", "oci://", and "--verify-signature"
to find instances to change).
- Around line 27-28: The doc currently declares Lola modules are packaged as
"single-layer OCI images" but the example outputs later show multiple content
layers; update the examples that describe image build/push output (the examples
currently showing multiple content layers) to reflect a single-layer model by
consolidating layers into one content layer in the output text, adjusting
sizes/digests/summary lines accordingly, and ensuring any CLI outputs or example
manifests referenced in the "single-layer OCI images" section are consistent
with that single-layer representation; search for the phrase "single-layer OCI
images" and the example blocks that show "content layers" and change those
outputs to a single-layer format.
- Around line 73-80: The Table of Contents contains anchor fragments that don't
match existing headings (e.g., entries like "#new-commands",
"#modified-commands", "#configuration", "#possible-implementation-phasing");
update each TOC link to the exact heading text used in the document (or
normalize the headings to match the TOC) so intra-doc navigation works—ensure
the TOC entries such as "New Commands", "Modified Commands", "Configuration",
and "Possible Implementation Phasing" map exactly to their corresponding
headings or change the headings to the slugified forms used in the TOC so
anchors like Module Metadata and SkillCard and Workflow Pattern: Add Then
Install resolve correctly.

---

Nitpick comments:
In `@docs/adr/0007-oci-format.md`:
- Line 445: Update the phrasing in the ADR text by replacing the phrase "CLI
interface compatibility (Click → Cobra)" with the concise "CLI compatibility
(Click → Cobra)"; locate the exact string "CLI interface compatibility (Click →
Cobra)" in docs/adr/0007-oci-format.md and change it to "CLI compatibility
(Click → Cobra)" so the word "interface" is removed.
- Line 365: Three fenced code blocks are missing language identifiers causing
MD040; update the three backtick fences that surround the blocks starting with
"OCI Image:", ".lola/modules/module-name/", and "lola (Go binary)" to use a
language tag (use "text") so each opening fence becomes ```text and the
corresponding closing fence remains ```, keeping the block contents unchanged;
apply the same change for the other occurrences mentioned (the blocks around
those three headings).

In `@docs/adr/0007-oci-format/oci-cli-exploration.md`:
- Line 29: The fenced code block that contains the tree diagram is missing a
language tag (triggering MD040); update the opening backtick fence for that
block (the fenced block beginning at the tree diagram around line 29) to include
the language tag "text" (e.g., ```text) so the markdown linter recognizes the
code block type.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: c44a68ff-1a38-4923-8a24-bf49119de34e

📥 Commits

Reviewing files that changed from the base of the PR and between a343c6e and 38715d1.

📒 Files selected for processing (2)
  • docs/adr/0007-oci-format.md
  • docs/adr/0007-oci-format/oci-cli-exploration.md

Comment thread docs/adr/oci-format/oci-cli-exploration.md
Comment thread docs/adr/0007-oci-format/oci-cli-exploration.md Outdated
Comment thread docs/adr/oci-format/oci-cli-exploration.md
Comment thread docs/adr/oci-format/oci-cli-exploration.md
SecKatie
SecKatie previously approved these changes May 29, 2026

@SecKatie SecKatie left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I love this idea so much and I think it goes great with the move to golang.

@mrbrandao have you read this yet?

@dmartinol my only feedback would be that you can probably reduce the length of this ADR

Comment thread docs/adr/0007-oci-format.md Outdated
@SecKatie

Copy link
Copy Markdown
Collaborator

Oh and @dmartinol can you rebase and fix some of the issues like the table of contents?

@mrbrandao

Copy link
Copy Markdown
Collaborator

I love this idea so much and I think it goes great with the move to golang.

@mrbrandao have you read this yet?

@dmartinol my only feedback would be that you can probably reduce the length of this ADR

@SecKatie Yes, I read ;-) Lets do it.

@dmartinol in the PR: #109 I'm accepting your proposal for ADR names. Please also rename the ADR to match the new name conventions.

@dmartinol

Copy link
Copy Markdown
Collaborator Author

@mrbrandao @SecKatie
pushed fix to review comments and shrunk the ADR as requested

@SecKatie SecKatie left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

One nit. I think this is good to go in without that being addressed. @dmartinol let me know if you want this merged as is.

Comment thread docs/adr/oci-format.md
err = artifact.ExtractTo("/path/to/.lola/modules/") // after verification succeeds
```

CLI command proposals (`lola build`, `lola push`, `lola sign`, `lola verify`, phasing, metadata schema) live in [OCI CLI Exploration](oci-format/oci-cli-exploration.md).

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I feel like we should recommend cosign for signing. I think lola verify makes sense but I'm not sure we want the liability for our users if our signing doesn't work properly.

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

same concern for lola sign, I imagine

@SecKatie SecKatie Jun 5, 2026

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think so. Do you want to hold this open and change that or is it okay and we can keep taking about it after this is merged?

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think so. Do you want to hold this open and change that or is it okay and we can keep taking about it after this is merged?

I think it's better to review the low level details at execution time. So I'd merge this as-is for now.

@dmartinol dmartinol Jun 11, 2026

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we merge it after the latest rebase?

@SecKatie

SecKatie commented Jun 5, 2026

Copy link
Copy Markdown
Collaborator

Oh and @dmartinol can you rebase? Sorry for all the back and forth 😅

dmartinol added 10 commits June 15, 2026 14:48
Signed-off-by: Daniele Martinoli <dmartino@redhat.com>
Signed-off-by: Daniele Martinoli <dmartino@redhat.com>
Signed-off-by: Daniele Martinoli <dmartino@redhat.com>
Signed-off-by: Daniele Martinoli <dmartino@redhat.com>
Signed-off-by: Daniele Martinoli <dmartino@redhat.com>
…OCI model.

Signed-off-by: Daniele Martinoli <dmartino@redhat.com>
Signed-off-by: Daniele Martinoli <dmartino@redhat.com>
Signed-off-by: Daniele Martinoli <dmartino@redhat.com>
…mentation

Signed-off-by: Daniele Martinoli <dmartino@redhat.com>
Signed-off-by: Daniele Martinoli <dmartino@redhat.com>
@SecKatie SecKatie merged commit f387775 into LobsterTrap:main Jun 15, 2026
6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants